/* 
 * File:   MaxMinDiscardStrategy.h
 * Author: root
 *
 * Created on December 9, 2008, 12:39 PM
 */

#ifndef _MAXMINDISCARDSTRATEGY_H
#define	_MAXMINDISCARDSTRATEGY_H

#include "DiscardStrategy.h"

class MaxMinDiscardStrategy : public DiscardStrategy {
    
    int decisionCertainty;
    
protected:
    
    virtual void setExecutionParameter(int index, int rangeFraction) {
    }
    
public:
    
    MaxMinDiscardStrategy() 
    : DiscardStrategy(string("MaxMinDiscardStrategy"), 0), decisionCertainty(0)
    {
    }

    MaxMinDiscardStrategy (int myWeight)
    : DiscardStrategy (myWeight), decisionCertainty(0)
    {
    }

    virtual int getDecisionCertainty() {
        return decisionCertainty;
    }
    
    virtual Strategy* getActiveInstance(int inst_weight) {
        return dynamic_cast<Strategy*>(new MaxMinDiscardStrategy(inst_weight));
    }

    virtual void opponentMove ( int opponent, const Move& move ) {}
    virtual int pickDiscard (CCardStack*, bool, const GameState* );
    
};

#endif	/* _MAXMINDISCARDSTRATEGY_H */

